<!--
 * @Author: King7
 * @Date: 2023-09-03 22:01:31
 * @LastEditors: King7
 * @LastEditTime: 2023-09-03 22:12:19
 * @Description: 测试slots
-->
<template>
  <div>
    <h1>这是header</h1>
    <slot name="header" :data="headerData"></slot>
    <h1>这是default</h1>
    <slot></slot>
    <h1>这是footer</h1>
    <slot name="footer" :data="footerData"></slot>
  </div>
</template>

<script setup lang="ts">
const headerData = {
  a: 1,
  b: 2
}
const footerData = {
  a: 100,
  b: 200
}
</script>

<style scoped>

</style>